package com.jeecms.wicool.manager.share.impl;

import com.jeecms.common.hibernate3.Updater;
import com.jeecms.common.page.Pagination;
import com.jeecms.wicool.dao.share.FoodShareDao;
import com.jeecms.wicool.dao.share.WealShareDao;
import com.jeecms.wicool.entity.share.FoodShare;
import com.jeecms.wicool.entity.share.WealShare;
import com.jeecms.wicool.manager.share.FoodShareMng;
import com.jeecms.wicool.manager.share.WealShareMng;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * Created by cuiyanlei on 15/6/17.
 */
@Transactional
@Service
public class WealShareMngImpl implements WealShareMng {
    @Override
    public WealShare save(WealShare bean) {
        return dao.save(bean);
    }

    @Override
    public WealShare deleteById(Integer id) {
        return dao.deleteById(id);
    }

    @Override
    public WealShare updateByUpdater(Updater<WealShare> updater) {
        return dao.updateByUpdater(updater);
    }

    @Override
    public WealShare findById(Integer id) {
        return dao.findById(id);
    }

    @Override
    public Pagination getPage(String title, String content, Integer pageNo, Integer pageSize) {
        return dao.getPage(title, content, pageNo, pageSize);
    }

    @Autowired
    private WealShareDao dao;
}
